<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="/struts-tags" prefix="s"%>
<%@taglib uri="/struts-dojo-tags" prefix="sx"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Pesquisar Matriz Curricular</title>
    </head>
    <body>
        <h1>Pesquisar Matriz Curricular</h1>

        <s:form action="MatrizCurricular">
            <s:select name="codCurso" label="Curso" list="cursos" listKey="codCurso" listValue="nome"></s:select>
            <s:submit action="pesquisarMatrizCurricular" value="Pesquisar"></s:submit>

                <table border>
                    <tr>
                        <td>
                            Disciplina
                        </td>
                        <td>
                            Período
                        </td>
                        <td>
                            Ementa
                        </td>
                    </tr>
                <s:iterator value="disciplinas">
                    <tr>
                        <td>
                            ${nome}
                        </td>
                        <td>
                            ${periodo}
                        </td>
                        <td>
                           <s:url id="visualizarMatrizCurricular" action="visualizarMatrizCurricular">
                            <s:param name="codDisciplina" value="%{codDisciplina}"></s:param>
                        </s:url>
                        <s:a href="%{visualizarMatrizCurricular}">Visualizar</s:a>
                        </td>
                    </tr>
                </s:iterator>
            </table>
            <s:submit action="voltarMatrizCurricular" value="Voltar"></s:submit>
        </s:form>
    </body>
</html>
